<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
	xmlns:h="http://java.sun.com/jsf/html"
	xmlns:f="http://java.sun.com/jsf/core"
	xmlns:ui="http://java.sun.com/jsf/facelets"
	xmlns:p="http://primefaces.org/ui">
<body>
	<ui:composition template="/template/template.xhtml">
		<ui:define name="title">#{aqarMsgs.Aqarat_Building_Building_PageTitle}</ui:define>
		<ui:define name="manuBar">
			<ui:include src="/controlling/aqarat/aqaratMenu.xhtml" />
		</ui:define>

		<ui:define name="content">
			<h:form id="b_frm">

				<p:panel header="#{aqarMsgs.Aqarat_Building_Building_AllBuildings}">
					<p:dataTable id="building_tb_list" value="#{buildingBean.builgingList}" var="building"
						paginator="true" rows="10" rowsPerPageTemplate="5,10,15,20,25">
						<p:column>
							<f:facet name="header">
								<h:outputText value="#{aqarMsgs.Aqarat_Building_Name}" />
							</f:facet>
							<f:facet name="footer">
								<h:outputText value="#{aqarMsgs.Aqarat_General_Total}" />
							</f:facet>
							<h:outputText value="#{building.name}" />
						</p:column>
						<p:column>
							<f:facet name="header">
								<h:outputText value="#{aqarMsgs.Aqarat_Building_NumberOfFloors}" />
							</f:facet>
							<f:facet name="footer">
								<h:outputText value=":" />
							</f:facet>
							<h:outputText value="#{building.numberOfFloors}" />
						</p:column>
						<p:column>
							<f:facet name="header">
								<h:outputText value="#{aqarMsgs.Aqarat_Building_Revenues}" />
							</f:facet>
							<h:outputText value="#{building.revenues}" />
							<f:facet name="footer">
								<h:outputText value="#{buildingBean.allBuildingsRevenues}" />
							</f:facet>
						</p:column>
						<p:column>
							<f:facet name="header">
								<h:outputText value="#{aqarMsgs.Aqarat_Building_Expenses}" />
							</f:facet>
							<f:facet name="footer">
								<h:outputText value="#{buildingBean.allBuildingsExpenses}" />
							</f:facet>
							<h:outputText value="#{building.expenses}" />
						</p:column>
						
						
						<f:facet name="footer">
							<h:commandLink>
								<p:graphicImage value="/resources/images/excel.png"
									style="border:0px;" alt="all Buildings" />
								<p:dataExporter type="xls" target="building_tb_list"
									fileName="Buildings" />
							</h:commandLink>
						</f:facet>
					</p:dataTable>
				</p:panel>
			</h:form>
		</ui:define>
	</ui:composition>
</body>
</html>
